package com.weiyuwqj.admin.controller.admin.debt;

import com.weiyuwqj.api.common.PageList;
import com.weiyuwqj.api.common.Paginator;
import com.weiyuwqj.api.model.BusDebtInvest;
import com.weiyuwqj.api.service.BusDebtInvestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Created by zhangyong on 2017/3/22.
 * 债权投资
 */
@Controller
@RequestMapping("/admin/debtInvest")
public class BusDebtInvestController {

    @Autowired
    private BusDebtInvestService debtInvestService;

    /**
     * 债权投资记录列表
     *
     * @param p          分页参数
     * @param debtInvest 债权投资记录对象
     * @return
     */
    @ResponseBody
    @RequestMapping("/getDebtInvestList")
    public Object getDebtInvestList(Paginator p, BusDebtInvest debtInvest) {
        PageList list = debtInvestService.getDebtInvestList(p, debtInvest);
        return list;
    }

}
